<%--
  Created by IntelliJ IDEA.
  User: 陈俊雄
  Date: 2018/5/28
  Time: 15:34
--%>
<%@ page contentType="text/html;charset=UTF-8" %>
<!-- Main view -->
<div class="animated fadeInRight">
    <div class="wrapper wrapper-content ng-scope" ng-controller="merchantWebsiteProTypeCtrl">
        <div class="row">
            <div class="col-lg-12">
                <div class="ibox float-e-margins">
                    <div class="ibox-title">
                        <h5>{{ 'MERCHANT_WEBSITE_PRO_TYPE' | translate }}</h5>
                    </div>
                    <div class="ibox-content sk-loading">
                        <div class="sk-spinner sk-spinner-wave">
                            <div class="sk-rect1"></div>
                            <div class="sk-rect2"></div>
                            <div class="sk-rect3"></div>
                            <div class="sk-rect4"></div>
                            <div class="sk-rect5"></div>
                        </div>
                        <div class="row">
                            <div class="col-lg-offset-1 col-lg-10">
                                <div class="col-sm-6 col-md-6 col-lg-3">
                                    <div class="form-group form-group-sm">
                                        <div class="input-group">
                                            <span class="input-group-addon">产品编码：</span>
                                            <input type="text" class="form-control" ng-model="searchInfo.productTypeId">
                                        </div>
                                    </div>
                                </div>
                                <div class="col-sm-6 col-md-6 col-lg-3">
                                    <div class="form-group form-group-sm">
                                        <div class="input-group">
                                            <span class="input-group-addon">类型名称：</span>
                                            <input type="text" class="form-control"
                                                   ng-model="searchInfo.productTypeName">
                                        </div>
                                    </div>
                                </div>
                                <div class="col-sm-6 col-md-6 col-lg-3">
                                    <div class="form-group form-group-sm">
                                        <div class="input-group">
                                            <span class="input-group-addon">创建时间：</span>
                                            <input type="text"
                                                   class="form-control"
                                                   ng-readonly="true"
                                                   ng-click="openDatepicker1()"
                                                   uib-datepicker-popup="{{format}}"
                                                   ng-model="searchInfo.createTime"
                                                   is-open="popup1.opend"
                                                   datepicker-options="dateOptions1"
                                                   alt-input-formats="altInputFormats"
                                                   close-text="关闭" clear-text="清空" current-text="今天"/>
                                            <span class="input-group-btn">
                                            <button type="button" class="btn btn-default btn-sm no-margins"
                                                    ng-click="openDatepicker1()">
                                                <i class="fa fa-calendar"></i>
                                            </button>
                                        </span>
                                        </div>
                                    </div>
                                </div>
                                <div class="col-sm-6 col-md-6 col-lg-3">
                                    <div class="form-group form-group-sm">
                                        <div class="input-group">
                                            <span class="input-group-addon">修改时间：</span>
                                            <input type="text"
                                                   class="form-control"
                                                   ng-readonly="true"
                                                   ng-click="openDatepicker2()"
                                                   uib-datepicker-popup="{{format}}"
                                                   ng-model="searchInfo.modifyTime"
                                                   is-open="popup2.opend"
                                                   datepicker-options="dateOptions2"
                                                   alt-input-formats="altInputFormats"
                                                   close-text="关闭" clear-text="清空" current-text="今天"/>
                                            <span class="input-group-btn">
                                            <button type="button" class="btn btn-default btn-sm no-margins"
                                                    ng-click="openDatepicker2()"
                                                    ng-disabled="endTimeDisable">
                                                <i class="fa fa-calendar"></i>
                                            </button>
                                        </span>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>
                        <div class="row">
                            <div class="col-sm-6 col-md-6 col-lg-3 col-lg-offset-3">
                                <button class="btn btn-sm btn-w-m btn-primary pull-right" ng-click="search(searchInfo)">
                                    查询
                                </button>
                            </div>
                            <div class="col-sm-6 col-md-6 col-lg-3">
                                <button class="btn btn-sm btn-w-m btn-info" ng-click="reset()">
                                    重置
                                </button>
                            </div>
                        </div>
                        <div class="hr-line-dashed"></div>
                        <button class="btn btn-sm btn-primary" ng-click="showModal(0)">新增</button>
                        <div class="table-responsive">
                            <table ng-table="merchantWebsiteProTypeTable"
                                   class="table table-condensed table-striped table-hover table-bordered">
                                <tr ng-repeat="row in $data">
                                    <td class="text-center p-6" style="width: 35px">
                                        <input type="checkbox" ng-model="selected[row.id]">
                                    </td>
                                    <td class="text-center" data-title="'产品类型名称'">
                                        {{row.productTypeName}}
                                    </td>
                                    <td class="text-center" data-title="'产品类型编码'">
                                        {{row.productTypeId}}
                                    </td>
                                    <td class="text-center" data-title="'备注'">
                                        {{row.remark}}
                                    </td>
                                    <td class="text-center" data-title="'创建人'">
                                        {{row.createUser}}
                                    </td>
                                    <td class="text-center" data-title="'创建时间'">
                                        {{row.createTime | date : 'yyyy/MM/dd'}}
                                    </td>
                                    <td class="text-center" data-title="'修改人'">
                                        {{row.modifyUser}}
                                    </td>
                                    <td class="text-center" data-title="'修改时间'">
                                        {{row.modifyTime | date : 'yyyy/MM/dd'}}
                                    </td>
                                    <td class="text-center" style="width: 78px" data-title="'操作（编辑）'">
                                        <div style="min-width: 78px">
                                            <button class="btn btn-xs btn-success no-margins" ng-click="edit(1, row)">
                                                编辑
                                            </button>
                                        </div>
                                    </td>
                                </tr>
                            </table>
                        </div>
                        <button class="btn btn-sm btn-primary pull-left" ng-click="del()" ng-disabled="delDisabled()">
                            删除
                        </button>
                        <my-pagination table-param="merchantWebsiteProTypeTable"></my-pagination>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>